package com.syh.jn.scm.infrastructure.repository.model.base.support;


import com.syh.core.ddd.infrastructure.repository.model.SuperBusinessModel;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.persistence.Column;
import javax.persistence.MappedSuperclass;

/**
 * 通用分类
 */
@MappedSuperclass
@Data
@EqualsAndHashCode(callSuper = false)
public abstract class SuperCategoryModel extends SuperBusinessModel {

  /**
   * 状态（-1：停用 1：启用）
   */
  @Column(name = "STATUS", columnDefinition = "smallint COMMENT '状态（-1：停用 1：启用）'")
  private Short status;
  /**
   * 上级分类id
   */
  @Column(name = "SUP_ID", columnDefinition = "bigint COMMENT '上级分类id'")
  private Long supId;

  /**
   * 目录树    格式：1-11-12  1：父父类id，11：父类id，12：当前id
   */
  @Column(name = "CATALOG_CODE", columnDefinition = "varchar(50) COMMENT '目录树'")
  private String catalogCode;

  /**
   * 分类编码
   */
  @Column(name = "CODE", columnDefinition = "varchar(50) COMMENT '分类编码'")
  private String code;
  /**
   * 类别名称
   */
  @Column(name = "NAME", columnDefinition = "varchar(50) COMMENT '类别名称'")
  private String name;
  /**
   * 排序等级
   */
  @Column(name = "ORDER_LEVEL", columnDefinition = "int COMMENT '排序等级'")
  private Integer orderLevel;
  /**
   * 分类等级
   */
  @Column(name = "CATE_LEVEL", columnDefinition = "int COMMENT '分类等级'")
  private Integer cateLevel;
  /**
   * 创建日期
   */
  @Column(name = "CREATE_TIME_STAMP", columnDefinition = "bigint COMMENT '创建日期'")
  private Long createTimeStamp;
  /**
   * 修改日期
   */
  @Column(name = "LAST_UPDATE_TIME_STAMP", columnDefinition = "bigint COMMENT '修改日期'")
  private Long lastUpdateTimeStamp;
}

